<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>动画效果示例</title>

    <style>
      body {
        background: #000;
      }

      div {
        position: relative;
        width: 120px;
        padding: 10px 0;
        height: 20px;
        left: 50%;
        top: 50%;
        color: #fff;
        text-align: center;
        margin-top: 100px;
        border-radius: 10px;
        overflow: hidden;
      }

      div:before {
        content: '';
        position: absolute;
        width: 200%;
        height: 200%;
        background: #ff722b;
        z-index: -2;
        left: 50%;
        top: 50%;
        animation: t 5s linear infinite;
        transform-origin: left top;
      }

      @keyframes t {
        to {
          transform: rotate(360deg);
        }
      }

      div:after {
        content: '';
        position: absolute;
        inset: 2px;
        background: #000;
        border-radius: inherit;
        z-index: -1;
      }
    </style>
  </head>
  <body>
    <div>边框按钮</div>
  </body>

  <script></script>
</html>
